package org.stream.answerduel.vo.Message;

import com.alibaba.fastjson.JSON;
import lombok.Data;

import java.util.List;

/**
 * 功能描述：存储题目消息的实体类
 *
 * @Auther: 苏建誉
 * @Date: 2019/7/11 22:48
 */
@Data
public class SubjectMessage extends Message{
    /**
     * 题目
     */
    private String title;
    /**
     * 题目选项
     */
    private List<String> option;

    private int currentIndex;//当前是第几题

    public SubjectMessage(){
        super(Type.subject);
    }
    public SubjectMessage(String title,List<String> option){
        super(Type.subject);
        this.title=title;
        this.option=option;
    }
    @Override
    public String toString(){
        return JSON.toJSONString(this);
    }
}
